package learn;

public class LearnException {

	public static void main(String[] args) {
		
		try {
			doSomething();
		} catch (DivideByZeroException e) {
			e.printStackTrace();
		}
		
		
		
	}
	
	public static void doSomething() throws DivideByZeroException{
		System.out.println(6/0);
	}
	
	
	
}

class DivideByZeroException extends ArithmeticException {
	
	/**
	 * 
	 */
	private static final long serialVersionUID = -5856182469514754291L;

	public DivideByZeroException() {
		super();
	}
	
	public DivideByZeroException(String s) {
		super(s);
	}
}
